package com.ruoyi.system.service.impl;

import com.ruoyi.system.domain.SysATrustCode;
import com.ruoyi.system.mapper.SysATrustCodeMapper;
import com.ruoyi.system.service.ISysATrustCodeService;
import lombok.AllArgsConstructor;
import org.springframework.stereotype.Service;

/**
 * @author renzhihao
 * @date 2024/04/30 14:30
 */
@Service
@AllArgsConstructor
public class SysATrustCodeServiceImpl implements ISysATrustCodeService {

    private final SysATrustCodeMapper sysAtrustCodeMapper;

    @Override
    public SysATrustCode selectByCode(String code) {
        return sysAtrustCodeMapper.selectByCode(code);
    }

    @Override
    public int insertCode(SysATrustCode sysAtrustCode) {
        return sysAtrustCodeMapper.insertCode(sysAtrustCode);
    }

    @Override
    public int deleteByCodeAndExpireTime(String code) {
        return sysAtrustCodeMapper.deleteByCodeAndExpireTime(code);
    }
}
